package com.aaa.system.dao;

import com.aaa.entity.Menu;
import com.aaa.entity.Role;
import com.baomidou.mybatisplus.core.mapper.BaseMapper;
import org.apache.ibatis.annotations.Param;

import java.util.List;

public interface RoleDao extends BaseMapper<Role> {
    List<Role> selectAll();

    List<Menu> queryMenusByRoleId(Integer roleId);

    List<Integer> queryMenuIdsByRoleId(Integer roleId);

    Integer batchInsertRoleMenu(@Param("roleId") Integer roleId,@Param("menuIds") String[] menuIds);

    Integer deleteByRoleId(Integer roleId);
}
